package com.galengao.listener;

import org.flowable.engine.delegate.TaskListener;
import org.flowable.task.service.delegate.DelegateTask;

/**
 * 自定义监听器
 *
 * @author GalenGao
 * @version Id: MyTaskListener.java, v 0.1 2022/9/15 14:31 GalenGao Exp $$
 */
public class MyTaskListener1 implements TaskListener {

    @Override
    public void notify(DelegateTask delegateTask) {

        if ("BU审批".equals(delegateTask.getName()) && "create".equals(delegateTask.getEventName())) {
            delegateTask.setAssignee("wen");
        }
    }
}
